Software Development
Classes and Objects in Java
Final Exam: Apprentice Developer
Java SE 13: Byte & Character Streams in Java
Java SE 13: Constructors & Other Methods
Java SE 13: Correctly Using Try-Catch-Finally Blocks
Java SE 13: More Operations on Member Variables & Methods
Java SE 13: Semantics of Method Invocation & Nested Classes
Java SE 13: Streams for Primitive Types, Objects, & Buffered IO
Java SE 13: Try-with-resources & Custom Exceptions
Java SE 13: Understanding Classes & Objects in Java
Java SE 13: Understanding Exception Handling in java
Java SE 13: Working with Files & Directories

Final Exam: Apprentice Developer

Course Number:
it_feadjd_01_enus
Lesson Objectives

Final Exam: Apprentice Developer

  • appropriately override the .toString method provided by the Object base class
  • combine multiple independent catch blocks using the | operator
  • copy a character file as a sequence of characters using the FileReader and FileReader classes
  • correctly chain constructors to achieve code reuse
  • correctly initialize objects of inner classes
  • correctly initialize objects of static nested classes
  • correctly invoke a method that throws an exception of a checked exception type
  • correctly use the throws clause while defining method signatures
  • create a custom exception object by extending the base class Exception, and throw an instance of this exception from your code
  • create and use enums (enumerated data types) in Java
  • create files using both the legacy java.io as well as the modern java.nio namespaces
  • create String objects using different input arguments and forms of memory allocation
  • create wrapper objects such as Integer, Float, etc. to encapsulate primitive (non-object) data types
  • customize IntelliJ to incorporate your individual preferences
  • define and invoke a parameterized constructor to instantiate objects of a class
  • define and invoke constructors in classes to correctly initialize member variables
  • define and invoke getter and setter methods to access private member variables of a class from outside that class
  • define and invoke multiple constructors to instantiate objects of a class
  • describe and use the -=, *=, %= and %= self-assignment operators
  • differentiate between equality tests based on the == operator and .equals
  • enumerate differences between checked exceptions, runtime exceptions, and errors
  • enumerate the important built-in exception classes in Java
  • identify differences between primitive and object types in Java
  • identify the situations when divide-by-zero exceptions arise
  • identify use-cases for the unary increment and decrement operators
  • implement the Serializable interface in user-defined classes so that they can be written to and read from using ObjectOutputStream and ObjectInputStream object
  • install Java on a Unix or Mac system
  • install the Eclipse IDE on a Mac-based system
  • invoke static and non-static methods of a class
  • list the reasons for Java’s popularity
  • make use of method overloading in your programs
  • modify control flow in a program using the if construct
  • perform conversions between variables of primitive types
  • perform operations such as copying and creating directories using the Files class in the java.nio namespace
  • perform operations such as copying files, checking for their existence, and deleting files using the Files class in the java.nio namespace
  • prematurely terminate loop execution using the break keyword
  • read a byte stream using the InputStream and FileInputStream classes
  • recognize how exceptions such as NullPointerException, NumberFormatException, and IndexOutOfBoundsException occur in code
  • recognize how variables of primitive types are governed by pass-by-value semantics in Java
  • recognize how variables of reference types are governed by pass-by-reference semantics in Java
  • recognize Java's class hierarchy for byte and character streams
  • recognize the exact semantics and limitations of the finally block
  • recognize the precise semantics of the try-with-resources construct in Java
  • recognize what member variables, static member variables, and member functions are
  • short-circuit execution of the current loop iteration using the continue keyword
  • throw an object of a built-in exception type in order to respond to an unexpected situation in a program
  • use enums (enumerated types) along with switch statements
  • use for loops to iteratively execute a block of code
  • use multiple independent catch blocks with a single try block
  • use nested if-else conditions to deal with mutually exclusive conditions
  • use strings in if-else constructs, relying on the .equals method and avoiding the == operator
  • use string variables in switch statements
  • use the DataOutputStream class to write primitive types and strings to byte streams
  • use the do-while loop control structure to ensure that the body of a loop is always executed at least once, regardless of the value of the loop variable
  • use the logical AND, logical OR, and logical negation operators
  • use the ObjectOutputStream class to write objects of any type to byte streams
  • use the StringBuffer object to perform string operations
  • use while loops to control the number of times a block of code executes based on the value of a specific expression
  • utilize both single-line as well as multi-line comments in Java
  • work with variables of double, char, and String types in Java

Overview/Description

Final Exam: Apprentice Developer will test your knowledge and application of the topics presented throughout the Apprentice Developer track of the Skillsoft Aspire Apprentice Developer to Journeyman Developer Journey.



Target

Prerequisites: none

Java SE 13: Byte & Character Streams in Java

Course Number:
it_jdcojdj_08_enus
Lesson Objectives

Java SE 13: Byte & Character Streams in Java

  • discover the key concepts covered in this course
  • recognize Java's class hierarchy for byte and character streams
  • read a byte stream using the InputStream and FileInputStream classes
  • apply the skip and available methods of FileInputStream objects and identify when the end of a byte stream has been reached
  • write a byte stream using the OutputStream and FileOutputStream classes
  • copy any file as a sequence of bytes using the FileInputStream and FileOutputStream classes
  • read a character stream using the FileReader and FileWriter classes
  • copy a character file as a sequence of characters using the FileReader and FileWriter classes
  • summarize the key concepts covered in this course

Overview/Description

In this series of video tutorials, you will learn about file and stream handling in Java with a strong conceptual foundation, before moving onto practical scenarios. Begin by learning how to navigate Java's complicated hierarchy of classes for dealing with byte and character streams. You will then learn how to apply the skip and available methods of FileInputStream objects and identify when the end of a byte stream has been reached. You will be able to write a byte stream by using the OutputStream and FileOutputStream classes, and then examine how to copy any file as a byte sequence using the FileInputStream and FileOutputSream classes. Move on to learning how to read a character stream using the FileReader and FileWriter classes. You will then copy a character file as a sequence of characters using the FileReader and FileWriter classes. At the end of the course, participants will be able to summarize the key concepts covered.



Target

Prerequisites: none

Java SE 13: Constructors & Other Methods

Course Number:
it_jdcojdj_02_enus
Lesson Objectives

Java SE 13: Constructors & Other Methods

  • discover the key concepts covered in this course
  • describe the initialization of member variables of class objects
  • define and invoke a parameterized constructor to instantiate objects of a class
  • define and invoke multiple constructors to instantiate objects of a class
  • use the this keyword appropriately inside the constructor and other methods of a class
  • define getter and setter methods to work with access protected member variables
  • use the this keyword appropriately inside getter and setter methods of a class
  • make use of method overloading in your programs
  • summarize the key concepts covered in this course

Overview/Description

The instantiation of objects in Java is the subject of this 9-video course, in which learners explore how each class has one or more constructor methods. This course examines the default, no-argument constructor provided by Java for each class and shows how constructors initialize member variables to a sensible initial state. Each learner will create his or her own defined class, instantiate that class, and use different types of constructors. You will learn to define your own parameterized constructor and will see that Java automatically removes the default no-argument constructor. Then explore how to implement correct getter and setter methods and to use the getter and setter methods to access member variables from outside a class, along with the use of the private access modifier to regulate such access. This course shows different overloaded methods in the context of constructors. Finally, you will learn that Java allows overloading constructors in a class, and how this ability allows one to create objects by using different methods.



Target

Prerequisites: none

Java SE 13: Correctly Using Try-Catch-Finally Blocks

Course Number:
it_jdcojdj_06_enus
Lesson Objectives

Java SE 13: Correctly Using Try-Catch-Finally Blocks

  • discover the key concepts covered in this course
  • identify the situations when divide-by-zero exceptions arise
  • apply the methods of the Exception base class to obtain exception information
  • use multiple independent catch blocks with a single try block
  • combine multiple independent catch blocks using the | operator
  • combine multiple related catch blocks using the | operator
  • employ correct exception-handling techniques for IO-intensive operations such as working with files
  • use the finally keyword to ensure correct release of file handles and other system resources
  • recognize the exact semantics and limitations of the finally block
  • correctly place the finally block relative to the catch blocks
  • summarize the key concepts covered in this course

Overview/Description

This course covers the bedrock of Exception Handling in Java, the try-catch-finally code structure. Participants will cover the class hierarchies in exception handling; the stream and file processing; and how Java's support for exceptions and streams is built around complex class structures. You will learn how code might result in exceptions that are enclosed within a try block. Because this code structure could result in a signal to Java that normal programming might be disrupted and will cause the code evaluation to be short-circuited, the course explores details of catch blocks, including the use of multiple catch blocks; the use of the pipe operator (operator) to chain different exceptions within the same catch block; and how catch blocks must be arranged for related exceptions. The last part of exception handling is the 'finally block.' This keyword (finally) is used to ensure the correct release of resources, such as file handles, no matter what handled or unhandled exceptions might arise within the try block.

|

Target

Prerequisites: none

Java SE 13: More Operations on Member Variables & Methods

Course Number:
it_jdcojdj_03_enus
Lesson Objectives

Java SE 13: More Operations on Member Variables & Methods

  • discover the key concepts covered in this course
  • appropriately override the .toString method provided by the Object base class
  • correctly chain constructors to achieve code reuse
  • identify use cases for static member variables
  • define and use static member variables
  • recognize how static methods can be accessed by instances of a class
  • invoke static and non-static methods of a class
  • summarize the key concepts covered in this course

Overview/Description

This course explores member functions and their invocation in Java. learners begin by studying object references and learning the subtleties and nuances of how these references sometimes lead to unexpected results in a program. Learn to use a copy constructor to break references that existed from rectangle objects to the point objects and how they become self-sufficient. Next, you will see that the classes you created often have multiple overloaded methods, which can lead to code duplication. You will learn how to correctly chain the implementations of overloaded constructors and other overload methods. You will also begin to understand the reference variable, 'this' keyword, to avoid naming conflicts in constructor chaining. You will see how to create variables or methods that ought to be one per class, rather than one per instance using the static keyword. Finally, you will become familiar with the different rules that govern how static members and methods are accessed, and how some forms of access that are allowed by the Java compiler are not considered a best practice.



Target

Prerequisites: none

Java SE 13: Semantics of Method Invocation & Nested Classes

Course Number:
it_jdcojdj_04_enus
Lesson Objectives

Java SE 13: Semantics of Method Invocation & Nested Classes

  • discover the key concepts covered in this course
  • use initialization blocks to appropriately initialize static and non-static member variables
  • recognize how variables of primitive types are governed by pass-by-value semantics in Java
  • recognize how variables of reference types are governed by pass-by-reference semantics in Java
  • avoid pitfalls related to re-initialization and modification of objects (reference types) while invoking functions in Java
  • correctly define static nested classes
  • correctly initialize objects of static nested classes
  • correctly define inner classes
  • correctly initialize objects of inner classes
  • summarize the key concepts covered in this course

Overview/Description

This course examines Java's support for exceptions and covers three specific topics: initialized blocks, the details of pass-by-value and pass-by-reference semantics, and the two types of nested classes. You will work in Java with initialization blocks on both static member values to construct static elements in your class and on non-static member variables as an alternative to constructors. This course uses examples of pass-by-value and pass-by-reference code to demonstrate how variables behave when they are passed from one function to another in arrays and strings. Next, learners explore the semantics of argument passing for primitive types, strings, and for objects. You will experiment with arrays and learn to use the Arrays.toString helper method. You will learn the rules and conventions that govern the two types of nested classes: static classes and inner classes. Finally, learn how a static class is created or nested inside a class, and how inner classes can logically group classes and interfaces in one place.



Target

Prerequisites: none

Java SE 13: Streams for Primitive Types, Objects, & Buffered IO

Course Number:
it_jdcojdj_09_enus
Lesson Objectives

Java SE 13: Streams for Primitive Types, Objects, & Buffered IO

  • discover the key concepts covered in this course
  • use the BufferedInputStream and BufferedOutputStream classes to efficiently interact with byte streams
  • use the BufferedReader and BufferedWriter classes to efficiently interact with character streams
  • use the DataOutputStream class to write primitive types and strings to byte streams
  • use the DataInputStream class to read primitive types and strings from byte streams
  • use the ObjectOutputStream class to write objects of any type to byte streams
  • use the ObjectInputStream class to read objects of any type from byte streams
  • implement the Serializable interface in user-defined classes so that they can be written to and read from using ObjectOutputStream and ObjectInputStream objects
  • summarize the key concepts covered in this course

Overview/Description

In this nine-video course, you will be focusing on Java's parallel class hierarchies for working with byte and character data and the various variants available to you. To begin, participants will learn how buffered stream handling saves on unnecessary inout-output (IO). Learn how to use the BufferedInputStream and BufferedOuputStream classes to interact efficiently with byte streams, and then to use the BufferedReader and BufferedWriter classes to interact efficiently with character streams. As you progress, you will explore how to use the DataOutputStream class to write primitive types and strings to byte strings, and the DataInputStream class to read primitive types and strings from byte streams. This leads participants to utilize the ObjectOutputStream class to write objects of any type to byte streams and the ObjectInputStream class to read objects of any type from byte streams. Finally, you will implement the Serializable interface in user-defined classes so that they can be written to and read from using ObjectOutputStream and ObjectInputStream objects.



Target

Prerequisites: none

Java SE 13: Try-with-resources & Custom Exceptions

Course Number:
it_jdcojdj_07_enus
Lesson Objectives

Java SE 13: Try-with-resources & Custom Exceptions

  • discover the key concepts covered in this course
  • correctly use the throws clause while defining method signatures
  • implement exception handling in a chain of methods that sequentially call each other
  • ensure that resources are automatically closed, relying on language support, using the try-with-resources construct
  • recognize the precise semantics of the try-with-resources construct in Java
  • throw an object of a built-in exception type in order to respond to an unexpected situation in a program
  • differentiate between the semantics of throwing runtime exceptions vs. throwing checked exceptions
  • correctly invoke a method that throws an exception of a checked exception type
  • correctly declare or handle exceptions in a chain of functions, each of which throws different types of exceptions
  • create a custom exception object by extending the base class Exception, and throw an instance of this exception from your code
  • instantiate and throw custom exception objects of both checked and unchecked exception types
  • summarize the key concepts covered in this course

Overview/Description

In this course, you will learn about the correct use of the throws clause, Java's relatively new try-with-resources construct, and the use of custom exceptions. Explore how to correctly use the throws clause while defining method signatures and implementing exception handling in a chain of methods that sequentially call each other. You will learn to ensure that resources are automatically closed, relying on language support, using the try-with-resources construct; and recognize the precise semantics of this construct in Java. This leads to throwing an object of a built-in exception type to respond to an unexpected situation in a program, and differentiating between the semantics of throwing runtime exceptions versus checked exceptions. The correct way to invoke a method that throws an exception of a checked exception type will be examined, along with how to correctly declare or handle exceptions in a chain of functions, each of which throws different types of exceptions. Finally, participants will explore the use of custom exceptions, defining their own exception classes, and then throwing exceptions that belong to those classes.



Target

Prerequisites: none

Java SE 13: Understanding Classes & Objects in Java

Course Number:
it_jdcojdj_01_enus
Lesson Objectives

Java SE 13: Understanding Classes & Objects in Java

  • discover the key concepts covered in this course
  • recognize what classes and objects are
  • recognize what member variables, static member variables, and member functions are
  • define a class and instantiate an object of that class in Java
  • print out the details of an object to the system console
  • define and invoke constructors in classes to correctly initialize member variables
  • define and invoke getter and setter methods to access private member variables of a class from outside that class
  • summarize the key concepts covered in this course

Overview/Description

What makes the programming language Java so useful is that can run on multiple platforms. In this course, you will examine Java and its support for object-oriented programming. This course uses real-world entities to demonstrate how member variables represent the state of those entities, and how member functions represent the behavior of those entities. Participants study the various basic types of variables in Java and distinctions between eight primitive types and strings, which are a type of object. You will learn that all basic building blocks of all operations are these basic types of variables. As a practical exercise, create a project in Java with Java's two basic building blocks, the twin concepts of classes and objects. Next, learn to create classes and instantiate objects of these classes. You will discover that all objects in Java come with certain built-in capabilities, because they all inherit from a common ancestor base class. Finally, participants learn how to use constructors, getter methods, and setter methods to configure and initialize Java objects.



Target

Prerequisites: none

Java SE 13: Understanding Exception Handling in java

Course Number:
it_jdcojdj_05_enus
Lesson Objectives

Java SE 13: Understanding Exception Handling in java

  • discover the key concepts covered in this course
  • define an exception and recognize how it disrupts program execution
  • describe and implement the catch-or-specify restriction
  • recognize how the JRE searches for an exception handler for an exception
  • enumerate the important built-in exception classes in Java
  • recognize how exceptions such as NullPointerException, NumberFormatException, and IndexOutOfBoundsException occur in code
  • identify differences between IO-related exceptions and other commonly encountered exceptions
  • enumerate differences between checked exceptions, runtime exceptions, and errors
  • summarize the key concepts covered in this course

Overview/Description

This course explores Exception Handling in Java and provides users with a strong conceptual and theoretical foundation and examines practical code-based scenarios. Begin by examining what exceptions are in Java and how Java’s class hierarchy addresses errors, runtime exceptions, and checked exceptions. An exception is an event that disrupts the normal flow when executing a program, and you will learn here how to differentiate between exceptions and errors. Participants will learn to use Java's catch-or-specify requirement on code that throws specific types of exceptions. You will also learn that an exception handler is code which deals with a particular exception, both its type and location, in the program. Next, learn the sequence of method calls or function calls which culminated in the exception being thrown. The course will then explore the common runtime exceptions, and see how input-output (IO)-related code often poses special challenges in exception handling. Finally, you will be shown how exception handling is tied to the try-catch keywords.



Target

Prerequisites: none

Java SE 13: Working with Files & Directories

Course Number:
it_jdcojdj_10_enus
Lesson Objectives

Java SE 13: Working with Files & Directories

  • discover the key concepts covered in this course
  • use the Path interface and the Paths.get methods to work with files and directories using the modern java.nio namespace
  • use the methods of the Path interface to normalize, parse, and resolve paths
  • create files using both the legacy java.io as well as the modern java.nio namespaces
  • perform operations such as copying files, checking for their existence, and deleting files using the Files class in the java.nio namespace
  • perform operations such as copying and creating directories using the Files class in the java.nio namespace
  • get and set file attributes (including both platform-agnostic as well as POSIX attributes), and query file stores for total and free space
  • create directories and iterate over their contents, including via the use of glob specifiers to filter directory contents
  • summarize the key concepts covered in this course

Overview/Description

In this course, participants learn more about Java's application programming interface (API) for working with files and directories. You will begin with the Path interface and the Paths.get methods to work with files and directories, which form the foundation of the modern java.nio APIs. You will then discover how to use the methods of the Path interface to normalize, parse, and resolve paths. Next, you will briefly detour into creating files using both the legacy java.io as well as the modern java.nio namespaces. Perform operations such as copying files, checking for their existence, and deleting files using the Files class in the java.nio namespace. Participants will also copy and create directories by using the Files class in the java.nio namespace. You will explore how to get and set file attributes (including both platform-agnostic as well as Portable Operating System Interface attributes), and query file stores for total and free space. Finally, learn how to create directories and iterate over their contents, including via the use of glob specifiers to filter directory contents.



Target

Prerequisites: none

Close Chat Live